﻿using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Web;
using FaceSharp.Api.GraphApi;
using FaceSharp.Api.Types;

namespace FaceSharp.Api.Objects
{
    public class Places : TypedGraphBase<PlaceType>
    {
        public Places(IFacebookCore facebookCore)
            : base(facebookCore)
        {
        }
        public IList<PlaceType> GetItemCheckins(long itemId)
        {
            Trace.Write("Begin Request", "GraphApi.ItemCheckins");
            var results = MakeGraphRequest(itemId.ToString(), "checkins");
            Trace.Write("End Request", "GraphApi.ItemCheckins");
            return results;
        }
        public IList<PlaceType> GetCheckInDetails(long checkInId)
        {
            Trace.Write("Begin Request", "GraphApi.ItemCheckins");
            var results = MakeGraphRequest(checkInId.ToString());
            Trace.Write("End Request", "GraphApi.ItemCheckins");
            return results;
        }
        public IList<PlaceType> GetRecentCheckins()
        {
            Trace.Write("Begin Request", "GraphApi.ItemCheckins");
            var results = MakeGraphSeach(objectType: "checkin");
            Trace.Write("End Request", "GraphApi.ItemCheckins");
            return results;
        }
    }
}